import { visualizer } from 'rollup-plugin-visualizer'

export default function createVisualizerConfig(isBuild: boolean) {
  if (!isBuild) {
    return []
  }

  return visualizer({
    open: true,
    gzipSize: true,
    brotliSize: true,
  })
}
